<template>
  <div class="log-in">
    <page-header></page-header>
    <login-message v-show="messageSeen"></login-message>
    <LoginMenu @click.native="registFunction" v-show="messageSeen" hintSentence="若要注册,请点击以下按钮" buttonClass="regist-button" buttonId="regist-button" buttonName="注册"></LoginMenu>
    <RegistMessage v-show="registSeen"></RegistMessage>
    <LoginMenu @click.native="returnFunction" v-show="registSeen" hintSentence="若要返回登录,请点击以下按钮" buttonClass="return-button" buttonId="return-button" buttonName="返回登录"></LoginMenu>
  </div>
</template>

<script>
import PageHeader from '../components/PageHeader.vue'
import LoginMessage from '../components/LoginMessage.vue'
import LoginMenu from '../components/LoginMenu.vue'
// import PageName from '../components/PageName.vue'
// import FunctionButtons from '../components/Button.vue'
import RegistMessage from '../components/RegistBox.vue'

export default {
  name: 'LoginPage',
  data: function () {
    return {
      messageSeen: true,
      registSeen: false
    }
  },
  components: {
    PageHeader,
    LoginMessage,
    LoginMenu,
    RegistMessage
    // FunctionButtons
  },
  methods: {
    registFunction: function () {
      this.messageSeen = false
      this.registSeen = true
    },
    returnFunction: function () {
      this.messageSeen = true
      this.registSeen = false
    }
  }
}
</script>

<style>
</style>
